package com.cksecurity.task;

public class ProducerTask extends BasicTask {
    
    @Override
    public void run() {
        boolean flag = true;
        int i = 0;
        while (flag) {
            logger.info("ProducerTask ...{}", Thread.currentThread().getId());
            try {
                sleep(5000);
                if (i == 5) flag = false;
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            i ++;
        }
    }

}
